package framework;

import java.util.Enumeration;

import javax.swing.UIDefaults;
import javax.swing.UIManager;

public class ListProperties {
  public static void main(String args[]) throws Exception {
    //UIManager.LookAndFeelInfo looks[] = UIManager.getInstalledLookAndFeels();
    
	UIManager.LookAndFeelInfo[] installedLookAndFeels = UIManager
			.getInstalledLookAndFeels();

    for (UIManager.LookAndFeelInfo info : installedLookAndFeels) {
      UIManager.setLookAndFeel(info.getClassName());

  	for (int idx = 0; idx < installedLookAndFeels.length; idx++)
		if ("Nimbus".equals(installedLookAndFeels[idx].getName())) {
			UIManager.setLookAndFeel(installedLookAndFeels[idx]
					.getClassName());
			break;
		}

      UIDefaults defaults = UIManager.getDefaults();
      Enumeration newKeys = defaults.keys();

      while (newKeys.hasMoreElements()) {
        Object obj = newKeys.nextElement();
        System.out.printf("%50s : %s\n", obj, UIManager.get(obj));
      }
    }
  }
}